package testcase;

import java.io.IOException;
import java.util.ArrayList;
import java.util.List;

import junit.framework.TestCase;
import wrongWordsHandling.ErrorsHandling;
import wrongWordsHandling.Suggestion;
import Data.DictionaryData;


public class WrongWordHandling extends TestCase{

	public void testSuggestion() throws IOException{
		DictionaryData.getDictionary();
		String wrongWord = "BOA";
		Suggestion suggestion = new Suggestion();
		List<String> result = new ArrayList<String>();

		result = suggestion.suggestion(wrongWord);
		System.out.print(result);
		assertEquals(true,true);
		
	}

/*	public void testSuggedtion2() throws IOException{
		DictionaryData.getDictionary();
		String wrongWord = "AOPPO";
		Suggestion suggestion = new Suggestion();
		assertEquals(true,true);
	}*/

	public void testSuggedtion3() throws IOException{
		DictionaryData.getDictionary();
		String wordNeededBeFind = "ZOPPO";
		Suggestion suggestion = new Suggestion();
		ErrorsHandling errorsHandling = new ErrorsHandling(suggestion);
		System.out.println(errorsHandling.suggestion(wordNeededBeFind));
		
		assertEquals(true,true);
	}
	public void testSuggedtion4() throws IOException{
		DictionaryData.getDictionary();
		String wordNeededBeFind = "ZOPPO";
		class SuggestionStub extends Suggestion{
			public List<String> suggestion(String wrongWord){
				return null;
			}
		}
		Suggestion suggestion = new SuggestionStub();
		ErrorsHandling errorsHandling = new ErrorsHandling(suggestion);
		System.out.println(errorsHandling.suggestion(wordNeededBeFind));
		
		assertEquals(true,true);
	}

}
